Site Payments Process API - Implementation Template
Setup guide
Please review the prerequisite instructions to configure Veeva Vault CTMS and SAP.
Importing Templates into Anypoint Studio
- In Studio, click the Exchange X icon in the upper left of the taskbar.
- Log in with your Anypoint Platform credentials.
- Search for the template.
- Click Open.
Running Templates in Anypoint Studio
After you import your template into Studio, follow these configuration steps to run it.
Common Configuration
mule.env- sets the environment where the application is to be deployed. It should be configured inconfig-<mule.env>.yamlfile. For a studio deployment, the recommended mule.env value islocal.mule.encryptionKey- sets the encryption password to be used for encrypting secure properties. Update as needed.
Please refer to the attached link on how to secure the configuration properties.
Site Payments Application Configuration
The application requires a few things to be configured, mainly the multiple system API connections information. Configure them in the properties file located in the config/properties folder.
veeva-sys-api.hostshould be configured inconfig-<mule.env>.yamlfile. URL for an instance of Veeva CTMS system API.veeva-sys-api.lifecycle-to-extracted-for-paymentshould be configured inconfig-<mule.env>.yamlfile. Its a lifecycle state to change the payment request status fromReady for PaymenttoExtracted for Payment.veeva-sys-api.lifecycle-to-completeshould be configured inconfig-<mule.env>.yamlfile. Its a lifecycle state to change the payment request status fromExtracted for PaymenttoPayment Completed.scheduler.veeva.frequencyshould be configured inconfig-<mule.env>.yamlfile. Modify to match the schedule desired to process payment requests from Veeva Vault CTMS. Defaulted to once a day.scheduler.veeva.startDelayshould be configured inconfig-<mule.env>.yamlfile. Modify to the amount of time to wait before triggering the first time to process payment requests from Veeva Vault CTMS. Defaulted to next day.scheduler.sap.frequencyshould be configured inconfig-<mule.env>.yamlfile. Modify to match the schedule desired to process cleared payments from SAP. Defaulted to once a day.scheduler.sap.startDelayshould be configured inconfig-<mule.env>.yamlfile. Modify to the amount of time to wait before triggering the first time to process cleared payments from SAP. Defaulted to next day.scheduler.sap.default-start-dateshould be configured inconfig-<mule.env>.yamlfile. Modify to the desired date to fetch cleared payments from SAP.sap-sys-api.hostshould be configured inconfig-<mule.env>.yamlfile. URL for your instance of target system api.sap-sys-api.journalEntry.senderSystemIdshould be configured inconfig-<mule.env>.yamlfile.sap-sys-api.journalEntry.recipientSystemIdshould be configured inconfig-<mule.env>.yamlfile.sap-sys-api.journalEntry.referenceDocumentTypeshould be configured inconfig-<mule.env>.yamlfile. Type of this business transaction document. Currently, the only allowed value in SAP is BKPFF (accounting document direct input).sap-sys-api.journalEntry.transactionTypeshould be configured inconfig-<mule.env>.yamlfile. It's a business transaction type that SAP supports.sap-sys-api.journalEntry.accountingDocumentTypeshould be configured inconfig-<mule.env>.yamlfile. It's document type of the accounting document.sap-sys-api.journalEntry.createdByshould be configured inconfig-<mule.env>.yamlfile. It's a communication user in SAP.
Run the application
- Right-click the template project folder.
- Hover your mouse over 'Run as'.
- Click Mule Application (configure).
- Inside the dialog, select Environment and set the variable
mule.envto the appropriate value (dev or local). - Inside the dialog, select Environment and set the variable encryptionKey to the property encryption key that you used to encrypt your secure properties.
- Click Run.
Deployment instructions for CloudHub using provided scripts
Ensure the Maven profile CloudHub-HLS-DEV has been properly configured in your settings.xml file. Reference can be found by downloading the Accelerator Common Resources asset. Additional instructions are available in the Getting Started with MuleSoft Accelerators - Build Environment guide.
Update the config-<env>.yaml properties appropriately and then use one of the following scripts to deploy the application to CloudHub:
- packageDeploy.sh (Mac/Linux).
- packageDeploy.cmd (Windows).